/*
 *  Arrow
 *
 *  Created by David Giovannini on 1/5/07.
 *  Copyright 2007 Software by Jove. All rights reserved.
 *
 */
 
#include "SBJ/Arrow/TimerFeed.h"

namespace SBJ
{

namespace Arrow
{

TimerFeed::TimerFeed( void )
{
}

TimerFeed::~TimerFeed( void )
{
}
	
void
TimerFeed::cancelMessage( Token token )
{
	m_invoker.cancelEntry( token );
}

bool
TimerFeed::start( void )
{
	m_invoker.start();
	return true;
}
	
bool
TimerFeed::stop( bool join )
{
	m_invoker.stop( join );
	return true;
}
	
bool
TimerFeed::addRouter( const IRouter::Ptr& router )
{
	m_router = router;
	return true;
}

bool
TimerFeed::removeRouter( const IRouter::Ptr& router )
{
	if ( m_router == router )
	{
		m_router.reset();
		return true;
	}
	return false;
}

}

}